package com.donger.business.bi.config;


import com.bstek.ureport.console.UReportServlet;
import org.springframework.boot.web.servlet.ServletRegistrationBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.ImportResource;

@Configuration
@ImportResource(UreportAutoConfiguration.CONTEXT)
public class UreportAutoConfiguration {

    static final String CONTEXT = "classpath:ureport-console-context.xml";

    @Bean
    public ServletRegistrationBean<UReportServlet> buildUreportServlet() {
        return new ServletRegistrationBean<>(new UReportServlet(), "/ureport/*");
    }

}
